package com.jimikongjian.models;

import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Repository;

import java.sql.Timestamp;

/**
 * Created by fuxiuyang on 17/2/19.
 */
@Scope("prototype")
@Repository("photo")
public class Photo {

    /**
     * 初始化id号，将id号置为-1
     */
    public static final int INIT_ID = -1;

    /**
     * 自身的id号
     */
    private int id;

    /**
     * 照片的存储地址
     */
    private String photoKey;

    /**
     * 所属相册的id号
     */
    private int albumId = Photo.INIT_ID;

    /**
     * 照片上传的时间
     */
    private Timestamp createTime;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getPhotoKey() {
        return photoKey;
    }

    public void setPhotoKey(String photoKey) {
        this.photoKey = photoKey;
    }

    public int getAlbumId() {
        return albumId;
    }

    public void setAlbumId(int albumId) {
        this.albumId = albumId;
    }

    public Timestamp getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Timestamp createTime) {
        this.createTime = createTime;
    }
}
